This invention relates in general to the field of data processing and in particular to a system and method for providing cross-dimensional computation and data access in an on-line-analytical processing (OLAP) environment.
It is often desirable in business or other planning environments to perform on-line analytical processing (OLAP) computations to generate desired data. For example, it may be desirable to compute the value of a Revenue data measure, according to the expression Revenue=Units*Price. Given a set of positions in a multi-dimensional database, this expression yields a value for the Revenue data measure according to the values of Units and Price for that set of positions. More generally, the value of a data measure (whether the value is stored in the database or computed at run-time) varies according to the particular combination of positions for which the data measure is being evaluated. A data measure depends on a dimension if a change of position in that dimension may change the value of the data measure.
With existing OLAP systems, data access is limited to the positions at which the data measure is being computedxe2x80x94no cross-dimensional access is provided to data associated with other positions. Furthermore, the data measures for which a value is being computed must depend on the same dimensions as other data measures in the expressionxe2x80x94the data measure being computed cannot depend on a dimension that is not depended on by at least one other data measure in the expression. As a result, these OLAP systems are unable to compute values for a variety of more sophisticated xe2x80x9cvirtualxe2x80x9d data measures for which the database lacks persistent storage and which must thus be computed at run-time. These and other disadvantages make previous OLAP systems inadequate for many purposes.
According to the present invention, disadvantages and problems associated with systems for generating data in on-line analytical processing (OLAP) environments have been substantially reduced or eliminated.
According to one embodiment of the present invention, a system for generating a value for a first attribute includes a database having one or more dimensions each including one or more members. The database includes one or more storage locations that are each associated with one member from each dimension in a set of one or more of the dimensions. A server evaluates an expression including at least one second attribute that depends on a set of one or more of the dimensions, the expression mapping at least one member of a first dimension on which the first attribute depends to at least one member of a second dimension on which the second attribute depends. The value for the first attribute is then generated according to the expression. In a more particular embodiment, the server and database operate in an on-line analytical processing (OLAP) environment. In other more particular embodiments, the first and second dimensions are aliases of at least one base dimension, the value for the first attribute is generated using cross-dimensional computation according to the mapping, and a value for the second attribute is generated using cross-dimensional data access according to the mapping.
The system and method of the present invention provide a number of important technical advantages. Unlike previous techniques, the system and method of the present invention provide cross-dimensional data access to positions other than those at which the data measure is being computed. Like at least some existing systems, the present invention allows values to be computed for xe2x80x9cvirtualxe2x80x9d data measures lacking persistent storage in the database. However, unlike previous techniques, the system and method of the present invention provide for cross-dimensional computation, such that a value may be computed for a virtual data measure that depends on one or more different dimensions than the other data measures in an associated computational expression. Using dimension aliases and appropriate mappings, the present invention provides these and other important benefits relative to existing OLAP systems. Other important technical advantages are apparent to those skilled in the art from the following figures, description, and claims.